import React from 'react';
import {BrowserRouter as Router, Route, Routes, Navigate} from 'react-router-dom';
import Login from './pages/login/Login.jsx';
import NavigationLayout from "./pages/layouts/NavigationLayout.jsx";
import HomePage from "./pages/homePage/HomePage.jsx";
import StudentPage from "./pages/studentPage/StudentPage.jsx"
import RegisteredPage from "./pages/registeredPage/RegisteredPage.jsx";
import AcademyPage from "./pages/academyPage/AcademyPage.jsx";
import SpecialtyPage from "./pages/specialtyPage/SpecialtyPage.jsx";
import ClassPage from "./pages/classPage/ClassPage.jsx";
import TeacherPage from "./pages/teacherPage/TeacherPage.jsx";

function App() {
    return (
        <Router>
            <Routes>
                <Route path="/" element={<Login/>}/>
                <Route path="/login" element={<Login/>}/>
                <Route path="/registered" element={<RegisteredPage/>}/>
                <Route path="/pages" element={<NavigationLayout/>}>
                    <Route index element={<Navigate to="home" replace/>}/>
                    <Route path="home" element={<HomePage/>}/>
                    <Route path="student" element={<StudentPage/>}/>
                    <Route path="academy" element={<AcademyPage/>}/>
                    <Route path="specialty" element={<SpecialtyPage/>}/>
                    <Route path="classPage" element={<ClassPage/>}/>
                    <Route path="teacher" element={<TeacherPage/>}/>
                </Route>
            </Routes>
        </Router>
    );
}

export default App;